package com.qqt.csr.im.dto;

import com.qqt.csr.im.entity.Account;
import com.qqt.csr.im.enums.ConversationStateEnum;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;

import java.io.Serial;
import java.io.Serializable;
import java.util.Date;
import java.util.List;

/**
 * @Author: yang hao
 * @Date: 2024/10/16 10:51
 * @Description: 会话 视图对象
 **/
@Data
@Builder
@NoArgsConstructor
@AllArgsConstructor
@Schema(description = "会话 视图对象")
public class ConversationDTO implements Serializable {

    @Serial
    private static final long serialVersionUID = 1L;

    @Schema(description = "主键")
    private String id;

    @Schema(description = "发起方")
    private Account initiator;

    @Schema(description = "房间id")
    private Long roomId;

    @Schema(description = "房间成员")
    private List<Account> roomMemberList;

    @Schema(description = "会话状态，0：结束，1：正常")
    private ConversationStateEnum state;

    @Schema(description = "会话开始时间")
    private Date startTime;

    @Schema(description = "会话结束时间")
    private Date endTime;

    @Schema(description = "扩展, Json格式")
    private String ext;

    @Schema(description = "创建时间")
    private Date createTime;

    @Schema(description = "更新时间")
    private Date updateTime;

}
